package com.webdrider.model.util;

import junit.framework.Assert;

import org.junit.Test;

import com.common.model.util.UserType;

public class UserTypeTest {

	@Test
	public void testEqualsOrGreaterSuccesfully() {
		UserType userType1 = UserType.USER;
		UserType userType2 = UserType.USER;
		
		Assert.assertTrue(userType1.equalsOrGreater(userType2));
		
		UserType userType3 = UserType.ADMIN;
		UserType userType4 = UserType.ADMIN;
		
		Assert.assertTrue(userType3.equalsOrGreater(userType4));
	}
	
	@Test
	public void testEqualsOrGreaterUserAdmin() {
		UserType userType1 = UserType.USER;
		UserType userType2 = UserType.ADMIN;
		
		Assert.assertFalse(userType1.equals(userType2));
		Assert.assertTrue(userType2.equalsOrGreater(userType1));
	}
}
